<?php

namespace app\purchase\controller;
use app\common\controller\PCBase;
use app\common\controller\DBase;
use app\purchase\logic\PurchaseSuggestLogic;
use  think\App;
class PurchaseSuggest extends PCBase
{

    /**
     * @desc   获取采购建议列表接口
     * @author luckyXiong
     * @date   2024-12-21
     */
    public function getSuggestList(){
        $params             = $this->request->post();
        return  (new PurchaseSuggestLogic())->getSuggestList($params);
    }


    /**
     * @desc   获取缺货建议列表接口
     * @author luckyXiong
     * @date   2024-12-21
     */
    public function getShortageList(){
        $params             = $this->request->post();
        return  (new PurchaseSuggestLogic())->getShortageList($params);
    }







    /**
     * @desc   暂不采购
     * @author luckyXiong
     * @date   2024-12-21
     */
    public function unPurchase(){
        $params             = $this->request->post();
        return  (new PurchaseSuggestLogic())->unPurchase($params);
    }


    /**
     * @desc   添加备注接口
     * @author luckyXiong
     * @date   2024-12-21
     */
    public function addRemark(){
        $params             = $this->request->post();
        return  (new PurchaseSuggestLogic())->addRemark($params);
    }


    /**
     * @desc   更换供货商接口
     * @author luckyXiong
     * @date   2024-12-21
     */
    public function changeSupply(){
        $params             = $this->request->post();
        return  (new PurchaseSuggestLogic())->changeSupply($params);
    }


    /**
     * @desc   更改采购数量
     * @author luckyXiong
     * @date   2025-03-21
     */
    public function update_purchase_quantity(){
        $params             = $this->request->post();
        return  (new PurchaseSuggestLogic())->update_purchase_quantity($params);
    }



    /**
     * @desc   加入采购计划接口
     * @author luckyXiong
     * @date   2025-03-21
     */
    public function removePlan(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->removePlan($params);
    }



    /**
     * @desc   获取采购计划列表
     * @author luckyXiong
     * @date   2025-03-21
     */
    public function suggestPlan(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->suggestPlan($params);
    }


    /**
     * @desc   获取购物车列表接口
     * @author luckyXiong
     * @date   2025-03-21
     */
    public function carPlan(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->carPlan($params);
    }


    /**
     * @desc   购物车删除数据接口
     * @author luckyXiong
     * @date   2025-03-21
     */
    public function delPlan(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->delPlan($params);
    }


    /**
     * @desc   购物车修改数据接口
     * @author luckyXiong
     * @date   2025-03-21
     */
    public function editPlan(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->editPlan($params);
    }


    /**
     * @desc   购物车修改数据接口
     * @author luckyXiong
     * @date   2025-03-24
     */
    public function addPlanSku(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->addPlanSku($params);
    }


    /**
     * @desc   购物车修改数据接口
     * @author luckyXiong
     * @date   2025-03-24
     */
    public function editOperater(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->editOperater($params);
    }


    /**
     * @desc   购物车提交采购单详情接口
     * @author luckyXiong
     * @date   2025-03-24
     */
    public function purchaseDetail(){
        $params     = $this->request->post();
        $params['admin_id'] = $this->getAdminId();
        return  (new PurchaseSuggestLogic())->purchaseDetail($params);
    }



    /**
     * @desc   购物车采购单写入采购主表
     * @author luckyXiong
     * @date   2025-03-24
     */
    public function purchaseSubmit(){
        $params     = $this->request->post();
        return  (new PurchaseSuggestLogic())->purchaseSubmit($params);
    }









}